import Vue from "vue";
import Vuex from "vuex";
import persistence from "vuex-uniapp-persistence"
import system from './modules/system'
import user from './modules/user'
Vue.use(Vuex)

const store = new Vuex.Store({
  state: {
    demo: "测试"
  },
  mutations: {
    changeDemo(state, demo) {
      state.demo = demo;
    }
  },
  actions: {},
  getters: {},
  modules: {
    system,
    user
  },
  plugins: [persistence()],
});

export default store